package it.unibo.mycruise.simulation;

import it.unibo.convoycruisecontrol.simulation.AbstractSimulatorStatusBoat;
import it.unibo.mycruise.boat.StatusBoat;

/**
 * @author ale
 * @version 1.0
 * @created 24-ott-2012 00:48:19
 */
public class SimulatorStatusBoat extends AbstractSimulatorStatusBoat {

	private boolean broken;

	/**
	 * 
	 * @param statusBoat Serve per simulare il nostro it.unibo.mycruise.boat.StatusBoat
	 */
	public SimulatorStatusBoat(StatusBoat statusBoat)
	{
		super(statusBoat.getSequencePosition());
	}

	/**
	 * 
	 * @param broken
	 */
	public void setBroken(boolean broken)
	{
		if(this.broken != broken)
		{
			this.broken = broken;
			fireBoatStatusEvent();
		}
	}
	
	public boolean isBroken(){
		return broken;
	}

}